<!DOCTYPE html>
<html lang="en">
<head>
    <meta charset="UTF-8">
    <meta http-equiv="X-UA-Compatible" content="IE=edge">
    <meta name="viewport" content="width=device-width, initial-scale=1.0">
    <title>Document</title>
</head>

<style>

    .center {
        width: 100px;
        position: absolute;
        top: 50%;
        left: 50%;
        transform: translate(-50%, -50%);
    }

    .loading {
        width: 50px;
        height: 40px;
        background: wheat;
        margin: auto;
        display: flex;
        justify-content: space-between;
        align-items: center;
    }
    .loading .item {
        width: 2px;
        /* height: 100%; */
        background: red;
        border-radius: 1px;
        animation: wave .8s infinite;
    }
    @keyframes wave {
        0% {
            height: 0%;
        }
        20% {
            height: 20%;
        }
        50% {
            height: 50%;
        }
        70% {
            height: 70%;
        }
        100% {
            height: 0%;
        }
    }

    .loading .item:nth-child(2) {
        animation-delay: 0.1s;
    }
    .loading .item:nth-child(3) {
        animation-delay: 0.2s;
    }
    .loading .item:nth-child(4) {
        animation-delay: 0.3s;
    }
    .loading .item:nth-child(5) {
        animation-delay: 0.4s;
    }
    .loading .item:nth-child(6) {
        animation-delay: 0.5s;
    }
    .loading .item:nth-child(7) {
        animation-delay: 0.6s;
    }
    .loading .item:nth-child(8) {
        animation-delay: 0.7s;
    }
</style>

<body>
    
</body>

<div class="center">
    <div class="loading">
        <div class="item"></div>
        <div class="item"></div>
        <div class="item"></div>
        <div class="item"></div>
        <div class="item"></div>
        <div class="item"></div>
        <div class="item"></div>
        <div class="item"></div>
    </div>
</div>


</html>